package com.wx.mall.user.feign;

import com.wx.mall.user.entity.Demo;
import com.wx.mall.user.service.IDemoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/feign/demo")
public class FeignDemoController {

    @Autowired
    IDemoService iDemoService;


    @GetMapping("/info")
    public Demo info(int id) {
        return iDemoService.getById(id);
    }

}
